class Student  {
    constructor(name,score) {
        this.name =  name;
        this.score = score
    }
    introduce() {
        console.log(`我是${this.name},考了${this.score}分`)
    }
}
const student = new Student("张三",99)
console.log("student",student)
student.introduce();

class Teacher  {
    constructor(name,subject) {
        this.name =  name;
        this.subject = subject;
    }
    teach() {
        console.log(`我是${this.name},教${this.subject}`)
    }
}
const teacher = new Teacher("哈默","前端");
console.log("teacher",teacher)
teacher.teach();

